<html><head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8"><title>StrokePath</title></head>
<body bgcolor="#EFF1F0" link="#3A3966" vlink="#000000" alink="#000000">
<font face="Verdana, sans-serif" size="2"><p align="center"><b><font size="4">StrokePath()</font></b></p>
<p><b>语法</b></p><blockquote>
<font color="#3A3966"><b>StrokePath</b></font>(Width.d [, Flags])</blockquote>

</blockquote>
<b>概要</b><br><blockquote>



Stroke the current drawing path with the current drawing source. This draws the path 
as a solid line. 
<br>
<br>
By default, the path is reset after calling this function. This can be prevented with the appropriate flags. 

 

</blockquote><p><b>参数</b></p><blockquote>
<style type="text/css">
table.parameters { border-spacing: 0px; border-style: none; border-collapse: collapse; }
table.parameters td { border-width: 1px; padding: 6px; border-style: solid; border-color: gray; vertical-align: top; font-family:Arial; font-size:10pt; }
</style>
<table width="90%" class="parameters">
<tr><td width="10%"><i>Width.d</i></td>
<td width="90%"> 
 
Specifies the width for the stroked line. 

 

</td></tr>
<tr><td><i>Flags (可选)</i></td>
<td> 
 
Specifies optional characteristics for the drawn stroke. This can be a combination of the following values: 
 
<pre><font face="Courier New, Courier, mono"size="2">  <font color="#924B72">#PB_Path_Default</font>       : No special behavior (default value)
  <font color="#924B72">#PB_Path_Preserve</font>      : Don't reset the path after this function
  <font color="#924B72">#PB_Path_RoundEnd</font>      : Draw the line(s) with a rounded ends
  <font color="#924B72">#PB_Path_SquareEnd</font>     : Draw the line(s) with a square box at the ends
  <font color="#924B72">#PB_Path_RoundCorner</font>   : Draw the line(s) with rounded corners
  <font color="#924B72">#PB_Path_DiagonalCorner</font>: Draw the line(s) with diagonally cut corners
</font></pre>

</td></tr>
</table>
</blockquote><p><b>返回值</b></p><blockquote>
无.


</blockquote><p><b>备注</b></p><blockquote>



The following image demonstrates the effect of the different flags. The Corner and End flags can 
be combined with the binary or ('|') operator to combine the effects. 


 


<p><img src="../HelpPictures/strokepath.png"></p>

</blockquote><p><b>示例</b></p><blockquote>


<pre><font face="Courier New, Courier, mono"size="2">  <b><font color="#3A3966">If</font></b> <font color="#3A3966">OpenWindow</font>(0, 0, 0, 400, 200, "VectorDrawing", <font color="#924B72">#PB_Window_SystemMenu</font> | <font color="#924B72">#PB_Window_ScreenCentered</font>)
<font color="#3A3966">    CanvasGadget</font>(0, 0, 0, 400, 200)

    <b><font color="#3A3966">If</font></b> <font color="#3A3966">StartVectorDrawing</font>(<font color="#3A3966">CanvasVectorOutput</font>(0))
    
<font color="#3A3966">      MovePathCursor</font>(40, 20)
      <b><font color="#3A3966">For</font></b> i = 1 <b><font color="#3A3966">To</font></b> 4
<font color="#3A3966">        AddPathLine</font>(80, 0, <font color="#924B72">#PB_Path_Relative</font>)
<font color="#3A3966">        AddPathLine</font>(0, 40, <font color="#924B72">#PB_Path_Relative</font>)
      <b><font color="#3A3966">Next</font></b> i
      
<font color="#3A3966">      VectorSourceColor</font>(<font color="#3A3966">RGBA</font>(255, 0, 0, 255))
<font color="#3A3966">      StrokePath</font>(20, <font color="#924B72">#PB_Path_RoundCorner</font>|<font color="#924B72">#PB_Path_RoundEnd</font>)
    
<font color="#3A3966">      StopVectorDrawing</font>()
    <b><font color="#3A3966">EndIf</font></b>
    
    <b><font color="#3A3966">Repeat</font></b>
      Event =<font color="#3A3966"> WaitWindowEvent</font>()
    <b><font color="#3A3966">Until</font></b> Event = <font color="#924B72">#PB_Event_CloseWindow</font>
  <b><font color="#3A3966">EndIf</font></b>
</font></pre>

<p><img src="../HelpPictures/strokepath2.png"></p>

</blockquote><p><b>参阅</b></p><blockquote>

<a href="fillpath.html">FillPath()</a>, <a href="dotpath.html">DotPath()</a>, <a href="dashpath.html">DashPath()</a>, <a href="customdashpath.html">CustomDashPath()</a>, <a href="isinsidestroke.html">IsInsideStroke()</a>, <a href="resetpath.html">ResetPath()</a> 

</Blockquote><p><b>已支持操作系统 </b><Blockquote>所有</Blockquote></p><center>&lt;- <a href=stopvectordrawing.html>StopVectorDrawing()</a> - <a href="index.html">VectorDrawing Index</a> - <a href="svgvectoroutput.html">SvgVectorOutput()</a> -&gt;<br><br>

</body></html>